//
//  InfomationController.m
//  FinancialProduct
//  信息披露
//  Created by Stella on 2017/8/29.
//  Copyright © 2017年 maq. All rights reserved.
//
#import "NetWorthController.h"
#import "TransactionInfoCell.h"
#import "InfomationController.h"
#import "CKPuslichTool.h"
#import "ReportController.h"
#import "NetListController.h"
#import "ReportListOneController.h"

@interface InfomationController ()
@property(nonatomic,strong)NSArray *dataArray;
@end

@implementation InfomationController

- (void)viewDidLoad {
    [super viewDidLoad];

    self.dataArray=@[@"净值查询",@"产品报告",@"产品公告"];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}
- (IBAction)goJingzhiChaxun:(id)sender {
    //净值查询
}
- (IBAction)goChanpinbaogao:(id)sender {
    //产品报告
}
- (IBAction)goChanpingonggao:(id)sender {
    //产品公告
}

#pragma mark - Table view data source
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
{
    return 50;
    
}
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
{
    
    return 1;
    
}

- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
    
    return self.dataArray.count;
    
}
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
    
    TransactionInfoCell *cell=[tableView dequeueReusableCellWithIdentifier:@"TransactionInfoCell" forIndexPath:indexPath];
    cell.selectionStyle=UITableViewCellSelectionStyleNone;
    cell.accessoryType=UITableViewCellAccessoryNone;
    cell.nameLa.text=_dataArray[indexPath.row];
    return cell;
}
- (CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section{
    
    return 0.01f;
}

- (CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section{
    return 0.01;
}
-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
    switch (indexPath.row) {
        case 0:
        {
            //净值查询
            NetListController *vc=(NetListController*)[CKPuslichTool getViewControllerFromStroyBoard:@"My" viewID:@"NetListController"];
            vc.title=@"净值查询";
            [self.navigationController pushViewController:vc animated:YES];
        }
            break;
        case 1:
        {
            //产品报告
            ReportListOneController *vc=(ReportListOneController*)[CKPuslichTool getViewControllerFromStroyBoard:@"My" viewID:@"ReportListOneController"];
            vc.title=@"产品报告";
            [self.navigationController pushViewController:vc animated:YES];

        }
            break;
        case 2:
        {
            //产品公告
            ReportListOneController *vc=(ReportListOneController*)[CKPuslichTool getViewControllerFromStroyBoard:@"My" viewID:@"ReportListOneController"];
//            ReportController *vc=(ReportController*)[CKPuslichTool getViewControllerFromStroyBoard:@"My" viewID:@"ReportController"];
            vc.title=@"产品公告";
            [self.navigationController pushViewController:vc animated:YES];
        }
            break;
            
        default:
            break;
    }

}


@end
